package com.briup.jd2511.jd2511bookstore.pojo;


import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.time.LocalDate;
import java.time.LocalDateTime;

/**
 * 用户实体
 */
@Schema(name = "User")
@Data
@NoArgsConstructor
@AllArgsConstructor
public class User implements Serializable {

	@Schema(name = "主键ID")
	private Integer id;

	@Schema(name = "登录用户名")
	private String username;

	@Schema(name = "登录密码")
	private String password;

	@Schema(name = "手机号")
	private String phone;

	@Schema(name = "用户头像")
	private String avatar;

	@Schema(name = "用户性别(0男，1女)")
	private String gender;

	@Schema(name = "用户状态(0正常，1禁用)")
	private Short status;

	@Schema(name = "用户生日")
	private LocalDate birthday;

	@Schema(name = "注册时间")
	private LocalDateTime registerTime;

	@Schema(name = "角色编号 1. 管理员 2. 普通用户")
	private Short roleId;

	@Schema(name = "用户是否开通会员")
	private Boolean isVip;

	@Schema(name = "用户会员到期时间")
	private LocalDateTime vipExpirationTime;

	@Schema(name = "用户默认的收货地址")
	private Short defaultAddressId;
}
